<script>
  export default {
    name: 'MyCategory',
    props:{
      content: String
    },
    data(){
      return {
        gameList:["英雄联盟","DOTA2","王者荣耀","穿越火线"],
      }
    }
  }
</script>

<template>
  <div class="category">
    <h3>{{content}}分类</h3>
    <slot :games="gameList">我是默认头部插槽，我指定了一个坑位等着对应的插槽内容进行在这插入</slot>
  </div>
</template>

<style>
  .category{
    width: 200px;
    height: 300px;
    background-color: teal;
  }
  h3{
    text-align: center;
    background-color: olive;
  }
  img{
    width: 100%;
  }
  video{
    width: 100%;
  }
</style>